NetworkInfo, NetworkChange and Ping Sample

The new NetworkInfo class provides access to a wealth of network related information including IP, IPv4, IPv6, TCP, and UDP network traffic statistics for all network interfaces. The NetworkChange class provides a way for applications to receive event notification when the IP address of a network interfaces changes. The Ping classes provide a way to determine whether a remote computer is accessible over the network. and track the packet statistics. Ping supports synchronous and asynchronous calls. With the asynchronous ping, the application remains responsive and functional, which is not the case with the synchronous ping.

This example lets you drill into the deep hierarchy of network interface information, as well as ping an IP address both synchronously and asynchronously. Finally, the application is registers with the NetworkAddressChanged and NetworkAvailabilityChanged events. Unplugging your network cable or disabling the Wireless card will cause the NetworkAddressChanged event to be triggered.

This sample requires the following to be installed: